package org.alanlau.spring.prosyfactorybean;

import org.alanlau.dynamic.jdk.TestDao;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

/**
 * @author alan
 * @version 1.0
 * @date 2020/1/12 10:47
 */
public class ProxyFactoryBeanTest {
    public static void main(String[] args) {
        ApplicationContext context = new ClassPathXmlApplicationContext("applicationContext.xml");
        TestDao testDao = (TestDao)context.getBean("testDaoProxy");
        testDao.save();
        System.out.println("===============");
        testDao.modify();
        System.out.println("===============");
        testDao.delete();
    }
}
